package IO;

/**
 * 使用enum关键字实现枚举类
 *  如果有多个常量使用,隔开
 *  定义常量对象  写在最前面
 *
 * @author
 * @version [版本], 创建时间:   更新时间:
 */
public class ENUM01 {
    public static void main(String[] args) {
        System.out.println(season.SUMMER);
    }
    public enum season{
        SPRING("冬天","得劲"),SUMMER("夏天","热");
        private String name;
        private String desc;
        private season(String name,String desc){
            this.name = name;
            this.desc = desc;
        }

        public String getName() {
            return name;
        }

        public String getDesc() {
            return desc;
        }

        @Override
        public String toString() {
            return "ENUM01{" +
                    "name='" + name + '\'' +
                    ", desc='" + desc + '\'' +
                    '}';
        }
    }
}
